Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
You are correct, over the last month I've played around with so many 18 series chips with C18, Swordfish etc. I got confused and forgot that I used Swordfish's software I²C routines.blueroomelectronics said:The 18F1320 doesn't have a MSSP, it does have a EUSART.
Pommie said:You are correct, over the last month I've played around with so many 18 series chips with C18, Swordfish etc. I got confused and forgot that I used Swordfish's software I²C routines.
Mike.
WVProfessor said:If I have to change parts I might as well look for the best one to do the whole job.
I want to make a small board that can run alone gathering a large number of analog measurements and then when connected send it over a serial port.
So I need a uart, an I2C port, an A/D and a clock.
I figured the internal clock is good enough.
A 10 bit A/D is fine.
The I2C is to talk to an EEPROM but maybe I need to switch to a USB memory stick.
I have a bunch of 20 pin narrow DIP wire wrap sockets.
I am an analog guy so I don't need help with that part.
This is just a home project so I hope to keep the cost to under $10.
Pommie said:Haven't tried GLCD with swordfish. That's something I should try, Unicorn+GLCD+Swordfish.
Speaking of GLCDs, I have just got my analogue clock working on the 16F886 in asm. I think it looks rather good.
Mike.
I thought it was plainly obvious that I was answering Bill's post. I answered your post immediately after that - I even quoted you. Did you not notice? Is WV some place where English is a second language?WVProfessor said:I have no idea what those words mean. Can you give me the long introduction?
Thanks.
Pommie said:The simplest way would be a bitbanged I²C serial EEPROM and use the hardware USART. If you want an accurate clock then you need a crystal or an external (I²C) clock. How often do you need to take a measurement? If you switch to a 18F1320 and use Swordfish basic I could probably knock the code together relatively quickly. I already have a board with a 18F1320+LCD+DS1307 RTC.
Mike.
Pommie said:I thought it was plainly obvious that I was answering Bill's post. I answered your post immediately after that - I even quoted you. Did you not notice? Is WV some place where English is a second language?
Mike.
http://www.blueroomelectronics.com/WVProfessor said:I just saw some interesting buzz words. I see some posts today that I didn't see yesterday. What is Unicorn?
**broken link removed**I guess GLCD is a graphic LCD.
Underwater??????????I got a bad feeling about LCDs after some underwater tests. They came apart from the board.
WVProfessor said:I have the feeling that I am re-inventing the wheel.
I just downloaded the free Swordfish.
The 18F1320 price is right.
I was going to make a measurement only once a minute.
I am not yet ready to give up a pin for the clock although I have a bucket full of crystals and crystal oscillators. I don't know what accuracy I can get or want.
I was going to use timer 0 or timer 1 in the 16f88 but have no idea how the civilized world designs the code.
I will try measuring battery voltage and temperature outside in the yard.
00192 ;********************************************************************
00193 ;* Message table input is from pcl, returns a character in w. *
00194 ;********************************************************************
00195 ; put in low memory since we can't cross a page boundary
0061 3907 00196 Msg ANDLW 0x07 ; restrict jump size
0062 0782 00197 addwf pcl,f ; computed jump
0063 286A 00198 goto Msg1
0064 28EF 00199 goto Msg2
0065 2905 00200 goto Msg3
0066 2922 00201 goto Msg4
0067 2950 00202 goto Msg5
0068 297E 00203 goto Msg6
0069 29AC 00204 goto Msg7
00205
006A 0823 00206 Msg1 MOVF inx,w ; get index
006B 0782 00207 ADDWF pcl,f ; point to char
006C 340D 340A 00208 DT CR,LF,"Commands are:",CR,LF
006E 3443 346F
0070 346D 346D
0072 3461 346E
0074 3464 3473
0076 3420 3461
0078 3472 3465
gpasm-0.12.1 beta osa.asm 4-8-2008 04:12:54 PAGE 5
LOC OBJECT CODE LINE SOURCE TEXT
VALUE
007A 343A 340D
007C 340A
007D 3453 3420 00209 DT "S for general state data,",CR,LF
007F 3466 346F
0081 3472 3420
0083 3467 3465
0085 346E 3465
0087 3472 3461
0089 346C 3420
008B 3473 3474
008D 3461 3474
008F 3465 3420
0091 3464 3461
0093 3474 3461
0095 342C 340D
0097 340A
0098 3454 3420 00210 DT "T for time, D to download, ",CR,LF
009A 3466 346F
009C 3472 3420
009E 3474 3469
00A0 346D 3465
00A2 342C 3420
00A4 3444 3420
00A6 3474 346F
00A8 3420 3464
00AA 346F 3477
00AC 346E 346C
00AE 346F 3461
00B0 3464 342C
00B2 3420 340D
00B4 340A
00B5 3441 3420 00211 DT "A to toggle A/D converter,",CR,LF
00B7 3474 346F
00B9 3420 3474
00BB 346F 3467
00BD 3467 346C
00BF 3465 3420
00C1 3441 342F
00C3 3444 3420
00C5 3463 346F
00C7 346E 3476
00C9 3465 3472
00CB 3474 3465
00CD 3472 342C
00CF 340D 340A
00D1 3449 3420 00212 DT "I to change sample interval. ",NULL
00D3 3474 346F
00D5 3420 3463
00D7 3468 3461
00D9 346E 3467
00DB 3465 3420
00DD 3473 3461
00DF 346D 3470
00E1 346C 3465
gpasm-0.12.1 beta osa.asm 4-8-2008 04:12:54 PAGE 6
LOC OBJECT CODE LINE SOURCE TEXT
VALUE
00E3 3420 3469
00E5 346E 3474
00E7 3465 3472
00E9 3476 3461
00EB 346C 342E
00ED 3420 3400
00213
00EF 0823 00214 Msg2 MOVF inx,w ; get index
00F0 0782 00215 ADDWF pcl,f ; point to char
00F1 340D 340A 00216 DT CR,LF,"A/D is toggled ",CR,LF,NULL
00F3 3441 342F
00F5 3444 3420
00F7 3469 3473
00F9 3420 3474
00FB 346F 3467
00FD 3467 346C
00FF 3465 3464
0101 3420 340D
0103 340A 3400
Nigel Goodwin said:Check my 8x8 LED matrix tutorial, which uses large tables for both the character font, and the scrolling messages. It's probably easier to do it that way, rather than have separate parts in different pages.
WVProfessor said:I got to and then got lost in the list. That is a lot of stuff, I hope to read some day. Which one?