Forum: Mikrocontroller und Digitale Elektronik tiny13 -> out of SRAM bei "dim as byte"


von dani (Gast)


Lesenswert?

Hallo,

normalerweise nutze ich den Tiny2313, Mega8 oder Mega32.

Jetzt wollte ich den tiny13 mit bascom nutzen.

Folgender Code:

$regfile = "attiny13.dat"                                   'Tiny13
$crystal = 8000000

'....................................................................... 
....

Dim Test As Byte

Do

   nop

Loop

End

'....................................................................... 
.....

Führt zu der Meldung "Out of SRAM space".
Hab ich was im Datenblatt übersehen oder geht das mit dem Tiny13 
wirklich nicht? Der Tiny13 hat 1k Flash, 64Byte EEprom und 64Byte SRAM.

Dani

von Paul Baumann (Gast)


Lesenswert?

Probier es mal so:
$regfile = "attiny13.dat"                                   'Tiny13
$crystal = 8000000
$hwstack = 10
$swstack = 10
$framesize = 20
'....................................................................... 
...

Dim Test As Byte

Do

   nop

Loop

End


MfG Paul

von dani (Gast)


Lesenswert?

Dankeschön, funktioniert.

Heist das, das die Tiny13-lib in bascom fehlerhaft ist?

Gruß Dani

Bitte melde dich an um einen Beitrag zu schreiben. Anmeldung ist kostenlos und dauert nur eine Minute.
Bestehender Account
Schon ein Account bei Google/GoogleMail? Keine Anmeldung erforderlich!
Mit Google-Account einloggen
Noch kein Account? Hier anmelden.