Author |
Message |
Topic: Memory Safe Programming |
albertsm
Replies: 2
Views: 224
|
Forum: Various Posted: Fri Mar 01, 2024 10:54 am Subject: Memory Safe Programming |
of course it is possible to have safe memory coding.
when you use POKE, OUT you need to take care that you ensure the address is correct. that is relatively simple.
when you have the concept of poi ... |
Topic: considerations about solar energy |
albertsm
Replies: 14
Views: 2480
|
Forum: Green Energy Posted: Thu Feb 29, 2024 9:54 pm Subject: considerations about solar energy |
here is a small update. using solar panels in our country has all kind of traps. the current situation is that when you have solar panels you can use them to power your home. in the summer when there ... |
Topic: DAT file copy to old version |
albertsm
Replies: 2
Views: 99
|
Forum: BASCOM-AVR old unsupported versions Posted: Thu Feb 29, 2024 12:56 pm Subject: DAT file copy to old version |
PB is different since it has more hardware.
but when you do not use them and use the PB as normal 328 it should work.
it cant hurt to test right? |
Topic: Audio amplifier with DSP |
albertsm
Replies: 19
Views: 19748
|
Forum: BASCOM Project Blog Posted: Wed Feb 28, 2024 8:51 pm Subject: Audio amplifier with DSP |
it looks great !
yes when status changes into 'not active' it is a problem. today i was looking up parts and many have long delivery times. others do not exist anymore.
i usually get an email from t ... |
Topic: Start Bascom with Profile? |
albertsm
Replies: 7
Views: 273
|
Forum: BASCOM-AVR Posted: Wed Feb 28, 2024 8:37 pm Subject: Start Bascom with Profile? |
yes this is a bug for the mcs boot loader. for other serial based progs it will work. it will be addressed in the next release. |
Topic: GETRC not working with AVR128DA32 |
albertsm
Replies: 8
Views: 192
|
Forum: BASCOM-AVR XTINY/MEGAX/AVRX Posted: Wed Feb 28, 2024 9:45 am Subject: GETRC not working with AVR128DA32 |
ok, when 2087 is released it will have this addressed. for xmega and xtiny you can then use any port register like pin, port and ddr |
Topic: GETRC not working with AVR128DA32 |
albertsm
Replies: 8
Views: 192
|
Forum: BASCOM-AVR XTINY/MEGAX/AVRX Posted: Tue Feb 27, 2024 8:15 pm Subject: GETRC not working with AVR128DA32 |
i see there is also a bug for xtiny.
the first lines should use AND and not OR
_GetRC:
#IF _XMEGA=0 and _XTINY=0 |
Topic: GETRC not working with AVR128DA32 |
albertsm
Replies: 8
Views: 192
|
Forum: BASCOM-AVR XTINY/MEGAX/AVRX Posted: Tue Feb 27, 2024 4:01 pm Subject: GETRC not working with AVR128DA32 |
addition:
for xtiny you also need to mod the mcs.lib
- open mcs.lib
- locate this code :
sbiw r30,8 ; TEMP FIX since we always get PORTx_IN address, we need to adjust to PORTx_DIR by subbi ... |
Topic: GETRC not working with AVR128DA32 |
albertsm
Replies: 8
Views: 192
|
Forum: BASCOM-AVR XTINY/MEGAX/AVRX Posted: Tue Feb 27, 2024 3:50 pm Subject: GETRC not working with AVR128DA32 |
for xmega and xtiny use DDR register instead of PIN register.
i think with support of xmega, the compiler did not change the pin to ddr and since xtiny was added later it has the same problem.
if it ... |
Topic: Start Bascom with Profile? |
albertsm
Replies: 7
Views: 273
|
Forum: BASCOM-AVR Posted: Sun Feb 25, 2024 1:01 pm Subject: Start Bascom with Profile? |
yes, MWS is one of the few that read the help
to use a 'profile' you can use Options, Select Settings file and create a copy. the copy can have different parameters.
when you specify the opti ... |
Topic: AVR128DA32 an AC1 interrupt |
albertsm
Replies: 4
Views: 103
|
Forum: BASCOM-AVR XTINY/MEGAX/AVRX Posted: Fri Feb 23, 2024 12:56 pm Subject: AVR128DA32 an AC1 interrupt |
in your config the int=enabled is missing.
in my answer i wrote ac0 but you use ac1 so that must be AC1_STATUS.0 = 1 '
but it must go inside the ISR !
further you need to define what you mean ... |
Topic: AVR128DA32 an AC1 interrupt |
albertsm
Replies: 4
Views: 103
|
Forum: BASCOM-AVR XTINY/MEGAX/AVRX Posted: Fri Feb 23, 2024 11:43 am Subject: AVR128DA32 an AC1 interrupt |
you need to add enable global interrupts.
also many interrupt flags in this series must be manual reset.
in this case : AC0_STATUS.0 = 1 'reset int flag by writing a 1 |
Topic: Mcucsr: 2.0.8.6 - Does not work, 2.0.8.5 - ALL OK |
albertsm
Replies: 20
Views: 348
|
Forum: BASCOM-AVR Posted: Thu Feb 22, 2024 11:49 am Subject: Mcucsr: 2.0.8.6 - Does not work, 2.0.8.5 - ALL OK |
even in 2075 saving mcucsr into r0 existed.
your code never worked since mcucsr was cleared before your code executed.
Dim Begunok As Byte
Begunok = Mcucsr: Mcucsr = 0
should be :
... |
Topic: Mcucsr: 2.0.8.6 - Does not work, 2.0.8.5 - ALL OK |
albertsm
Replies: 20
Views: 348
|
Forum: BASCOM-AVR Posted: Thu Feb 22, 2024 11:35 am Subject: Mcucsr: 2.0.8.6 - Does not work, 2.0.8.5 - ALL OK |
but i do not think these projects were using 2085?
anyway since the first version of bascom-avr the compiler clears the watchdog flags, since otherwise a processor could hang.
only later the registe ... |
Topic: Mcucsr: 2.0.8.6 - Does not work, 2.0.8.5 - ALL OK |
albertsm
Replies: 20
Views: 348
|
Forum: BASCOM-AVR Posted: Thu Feb 22, 2024 10:46 am Subject: Mcucsr: 2.0.8.6 - Does not work, 2.0.8.5 - ALL OK |
beside all that your code is wrong too.
you must not reset mcucsr to 0. the compiler already does that for you. |
|