Seems Microchip started calling the SSPCON register SSPCON1 with the 16F87XA series and the 18F devices. Weird tho because the newer 16F88X series still uses the SSPCON. Anyway the 16F87XA devices could use the change in chipdata files, or maybe just make SSPCON1 equal to SSPCON, because it looks like the same bits?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If the same bits are the same, and they don't share their name with any other bits in other variables, then it should be possible to just refer to the bits by name. GCBASIC will automatically detect the variable that they come from.
Point taken though and I will look at giving GCBASIC the ability to automatically replace SSPCON1 with SSPCON or vice versa, depending on the chip being used.
If there is one really major thing that I wish Microchip had done differently, it would be to have used the same name consistently for the same bit/variable/config setting in different chips!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Yes, the different register/variable thing is confusing. Mostly pointed this out because the 18F87XA series are so popular and the chipdata varies from the data sheet. For some reason MPASM didn't complain when setting SSPCON for the 16F877A, so go figure. It did complain with the 18F device, no big deal, will set the bits instead.
If you like, I could try my hand at the master I2C documentation? I think I have the document program downloaded somewhere.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Seems Microchip started calling the SSPCON register SSPCON1 with the 16F87XA series and the 18F devices. Weird tho because the newer 16F88X series still uses the SSPCON. Anyway the 16F87XA devices could use the change in chipdata files, or maybe just make SSPCON1 equal to SSPCON, because it looks like the same bits?
If the same bits are the same, and they don't share their name with any other bits in other variables, then it should be possible to just refer to the bits by name. GCBASIC will automatically detect the variable that they come from.
Point taken though and I will look at giving GCBASIC the ability to automatically replace SSPCON1 with SSPCON or vice versa, depending on the chip being used.
If there is one really major thing that I wish Microchip had done differently, it would be to have used the same name consistently for the same bit/variable/config setting in different chips!
Yes, the different register/variable thing is confusing. Mostly pointed this out because the 18F87XA series are so popular and the chipdata varies from the data sheet. For some reason MPASM didn't complain when setting SSPCON for the 16F877A, so go figure. It did complain with the 18F device, no big deal, will set the bits instead.
If you like, I could try my hand at the master I2C documentation? I think I have the document program downloaded somewhere.