Hi Ian ! :smt058 Again many thanks,Yes it works very fine :evil: unfortunatly I have to change my PC, and I lost a lot of time to rebuild the new one, Fortunatly I have a backup :wink: [quote:ce27339315]these qwicc modules are very nice.[/quote:ce27339315] yes and not yes : because they are easy to plug not : the tmp117 is placed in the centre of the circuit and therefore difficult to put it in contact with a part to control the temperature. With a little searching, one can find a better constructed circuit where the tmp117 is placed on top of the circuit.
JP requested someone to help him with getting a tmp117 temperature sensor working in Bascom (https://www.mcselec.com/index2.php?option=com_forum&Itemid=59&page=viewtopic&t=14772), and I had a bit of free time, so here's the bascom tmp117 Bascom driver.
The code is based on code from SparkFun arduino lib at https://github.com/sparkfunX/Qwiic_TMP117
The code to store defaults in the EEPROM is untested, but it should work. All other functions have be tested.
interrupt : 'On Pinc.3 Isr_portc does not exist. this should be : On Portc_int Isr_portc
writing to PIN register can be done since it is a register, but it is intended for reading. so it will not do much. On some AVR chips writing to PIN will toggle the PORT. Not so on Xtiny. So best use the PORT register for this.
config powermode seems to have a bug for xtiny. but you an simply use a work around : [code:1:15a3fd7723]SLPCTRL_CTRLA=1 !sleep [/code:1:15a3fd7723]
for IDLE you write a 1 for STANDBY you write 3 and for powerdown you write 5
Error : 117 Line : 14 Unknown interrupt [PINC.3] Error : 86 Line : 20 Invalid parameter for CONFIG parameter or value Error : 86 Li[ne : 20 Invalid parameter for CONFIG parameter or value Error : 372 Line : 20 SE entry missing in DAT file Error : 124 Line : 20 LOOP expected
Who can give me a hand? Thanks in advance. Best regards
[b:a589e22e79][color=red:a589e22e79](BASCOM-AVR version : 22.214.171.124 )[/b:a589e22e79][/color:a589e22e79]
[quote:7c87171c4f="EDC"]There are specialized chips for that such of "address conflicts" If this is only hobby "one or two units" project then use TCA9548A or simillar. Only if cost of one of the "thousants" piece matter then it is worth to write those routines. ... Or maybe you have a lot of time to spent on your favoured hobby [/quote:7c87171c4f] The one and only reason would be, if he runs out of free pins, otherwise the plain solution is to use multibus I2C for everything, as it's most cost- and time-effective. I see no requirement to use the hard-TWI module for the described setup.
[quote:4985232105="Duval JP"]3 sensors with the same address and 1 with the same address + the RTC address.[/quote:4985232105] If you don't want to spare pins, you can give each of the 5 slaves its very own channel, afaics multibus supports 16 buses.
There are specialized chips for that such of "conflicts" If this is only hobby one or two pieces project then use TCA9548A or simillar. Only if cost of one of the "thousants" piece matter then it is worth to write those routines. Or maybe you have a lot of time to spent on your favoured hobby