Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - thepenguin77

Pages: 1 ... 50 51 [52] 53 54 ... 108
766
O.O

I was just going to come here and do that.  :D

767
ASM / Re: help me with the string commands
« on: July 04, 2011, 05:11:23 pm »
thepenguin77: would it work any better to use CPI/CPIR? Just a question.
I could make it faster, but it would be bigger, so it's a trade.

Yep. Faster, but bigger. You could make it yourself, it would give you valuable experience with cpi, which is used once like every 10 programs.

768
ASM / Re: App Programming
« on: July 04, 2011, 03:14:16 pm »
By your edit, you are referring to zStart, correct? But, no it will likely be between 20 and 30k.

You can do it without zStart. In fact, you really shouldn't rely on zStart. The code to do it is only about 30 bytes. But if it's going to end up around 30k, then it should go in an app.

769
TI Z80 / Re: zStart - an app that runs on ram clears
« on: July 04, 2011, 01:41:06 am »
Ok, good call on those. I know why the numbers 1-0 cause the glitch. It's because you aren't highlighting the one you are going to pick. If I can figure out how to make that work, it might make the whole process easier than what I do now.

Omnicalc's fast apps is a hard one though, I don't think it follows all the rules. (You can get to the regular program menu from it.) But nonetheless, I'll try to stop whatever it's doing.

770
ASM / Re: help me with the string commands
« on: July 03, 2011, 01:18:51 am »
It's not hard to do in Mimas, just do this:
Code: [Select]
.db 5
.db "Hello"

771
ASM / Re: help me with the string commands
« on: July 03, 2011, 12:51:46 am »
I think this is around what you want:

Code: [Select]
;############################
;input: hl = start of string
; de = string to find
;output: hl = start of string in string
; b = offset to start of string
; carry if string not found

inString:
ld b, 0
inStringLp:
ld a, (hl)
or a
scf
ret z
ld a, (de)
cp (hl)
jr nz, notAMatch

push hl
push de
checkMatchLoop:
inc hl
inc de

ld a, (de)
or a
jr nz, notTotalMatch

pop de
pop hl
ret
notTotalMatch:
cp (hl)
jr z, checkMatchLoop

pop de
pop hl


notAMatch:
inc b
inc hl
jr inStringLp

I could make it faster, but it would be bigger, so it's a trade.

Edit:
    After reading that section of 28 days, I should mention that you need to use zero terminated strings for this. You will almost never use length prefixed, so don't worry about that.

772
ASM / Re: App Programming
« on: July 02, 2011, 08:02:15 pm »
Writing the app is pretty simple if you use spasm. You don't really have to change much, aside from changing the output file name to .8xk.

Here is what I wrote in a topic a while back:
1. Your code will be running from the $4000-$7FFF page, which means you need to do .org $4000 instead of .org $9D95
2. You need a header, (which you can get from here)
3. You will have to use bcall(_jForceCMDNoChar) or similar to return as the OS jp's to the app, it doesn't call it
4. Most bcall's that take ptr's for inputs won't work if you give them an address in the $4000-$7FFF area. What this means is that you either need to reimplement bcall(_putS) with bcall(_putC), or copy all your strings to ram before displaying them
5. Obviously, don't change port 06 unless you have copied your routine to ram


6. And most importantly, you must compile your program for hex and then sign it, I would highly suggest that you just use spasm and make the output .8xk rather than .8xp. This will save you a lot of trouble.

Edit:
    And if your program size is going to be <20KB, you might want to consider making it a program since now we can run code at >C000.

773
News / Re: FLASHY - 83/4 series boot code modification
« on: July 02, 2011, 01:21:32 pm »
Calcdude, I figured out that you only have to execute code in a bank controlled by port (06).
Ah, okay. Do we still not know why just executing TI's code from bank 1 directly doesn't work?

I did something else wrong, it works now. (I almost feel like I didn't press ON.)

774
News / Re: FLASHY - 83/4 series boot code modification
« on: July 02, 2011, 01:00:57 pm »
Calcdude, I figured out that you only have to execute code in a bank controlled by port (06).

Also, I figured out what was wrong with the LCD, I had a few "ld ($10), a" where I should have had "out ($10), a"

775
ASM / Re: List of Bytes/Time each command takes?
« on: July 02, 2011, 09:22:35 am »
Oh, boy jerros, these are so many.

1. There is zilog's official documentation. It's drawn out over the course of a pdf, but it's really in depth.
2. Learn asm in 28 days has a set of pages containing almost all of the instructions. (It is missing a few like jp (hl))
3. There's this cool table. (Although it doesn't have t-states and the bytes take some figuring.
4. WikiTi has a page on the matter.

So there are four. Of those four, I personally use 2, and if I want to be absolutely sure of something, I use 1. Option 4 is probably the best "table," but it could use some color.

Edit:
    I never realized how in depth zilog's manual is. They give an example of each instruction.

776
News / Re: FLASHY - 83/4 series boot code modification
« on: July 02, 2011, 09:09:13 am »
I personally tested it on my real 83+SE, 84+, and 84+SE calculators, and several other people have used it multiple times without incident. I have yet to brick a calculator using this program, even after making some pretty scary patches.

That's me. I've flashed like 12 images or so to my calculator, so I can confirm to you that it works. Just be sure to test it first in wabbitemu. Buckeye's latest debug release allows boot code modification and includes everything new we learned about the calculator hardware on boot (which is weird). If you are going to mod a page, be sure to test it because I've bricked wabbitemu about 6 times.

And I haven't said it yet, but great job Brandon!

777
Other Calculators / Re: State of the Calculator at Boot
« on: July 01, 2011, 12:27:51 pm »
If anyone is interested, I made a boot image that jumps to $C000 after doing nothing to the calculator but unlock flash, not a single port besides 14h has been touched.

Although, for me to send this to you, you need to have some qualifications. You can erase the boot code in 5 bytes here, and as of writing this, I still can't turn the LCD on. So basically, in order for me to send you the stuff, you should know how to modify the OS, that's about the experience level you need.

Edit:
   Also, you have to have some way of pulling the link lines low. I use headphones, but a paper clip might work just as well.

778
News / Re: Duplicate attachment file name glitch fixed
« on: July 01, 2011, 11:17:12 am »
Thank you so much. Now I can finally just upload a file without trying to figure out if that name has ever been used before. Now, I won't have to tack on "zzz" to my uploads.

I also lost an entire 4 paragraph post the other day due to refresh not working...

779
Other Calculators / State of the Calculator at Boot
« on: June 30, 2011, 11:28:18 pm »
This topic is mostly for documenting stuff we find so it doesn't all stay on IRC. Keep discussing on IRC, but if any important discoveries are made, we'll put them here.

All this information was provided by reflashing my boot code: (thanks to brandonW for the flasher)





At boot, we now know that the memory mapping is as follows:
0000h - 3FFFh: Page 7F - boot code execution
4000h - 7FFFh: Page 00
8000h - BFFFh: Page 00
C000h - FFFFh: Ram Page 00

The way to return page 00 to 0000h is to execute on a page pointed to by port (06h). This is either the $4000h bank in memory map mode 0 or both the $4000 bank and the $8000 bank in memory map mode 1.

780
Hot_Dog, the only reason that wouldn't work is because flash isn't actually unlocked. So check port (02), port (25h), and port (26h) and make sure that everything looks correct.


DrDnar, don't forget about ports 0Bh and 0Ch.

Pages: 1 ... 50 51 [52] 53 54 ... 108