Pages: 1 [2] 3 4 ... 7   Go Down
Author Topic: The VideoBlaster Hi Resolution TVout platform  (Read 6455 times)
0 Members and 1 Guest are viewing this topic.
Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 118
Posts: 4545
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I need to find a way to include pure AVR assembler into my functions.

You'd have to use the command line.

I think Atmel studio would work, too.

Both of those make it very difficult to distribute code to Arduino users.

Another way would be to write a little program to convert ASM to Arduino-inline-style for compiling in the Arduino IDE. If you click the "Use External Editor" box in preferences you can change the files on disk and it will reload them when you hit 'compile'.

« Last Edit: November 20, 2013, 03:35:03 pm by fungus » Logged

No, I don't answer questions sent in private messages...

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Another way would be to write a little program to convert ASM to Arduino-inline-style for compiling in the Arduino IDE. If you click the "Use External Editor" box in preferences you can change the files on disk and it will reload them when you hit 'compile'.

I have though of that.
Logged

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I have an 8MHz pixelclock.

31500Hz Hsync is 8000000/31500=254pixels/line.
254pixels on the line makes 31 characters/line and perhaps 24-26visible.

VGA is doable.

This is not about doing some elevator or 3-axis milling machine.
This is cycle hunting.

And C++ or any other compiler is not going to work.
« Last Edit: November 20, 2013, 05:50:55 pm by janost » Logged

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi, I get this error -
const unsigned char charROM [8] [128] PROGMEM = { 0x1C , ... , 0xFF }; //Contains the PETSCII Font for characters 0-127

Expected primary-expression before '...' token

Thanks. Dave.

The format is simple.
Put 128 bytes for the first row in all your characters and then the next 128 rows and so on.

I really cant put any copyright material here even if it is as simple as a font.
Logged

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 118
Posts: 4545
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I really cant put any copyright material here even if it is as simple as a font.

Lots of 8x8 fonts here: http://dwarffortresswiki.org/index.php/Tileset_repository#Anikki

Logged

No, I don't answer questions sent in private messages...

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Can I use avrasm or wavrasm with ATmega328 and 644 or must I have AVR Studio 3000.0?
Am I going to strike on some mnemonics it doesnt support?

Doing AVR assembler is really fun without C and the bloated Arduino IDE.
I have based my future designs on the ATtiny85, ATmega328 and ATmega644.

But I need to know that I havent painted myself into a corner?
Logged

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The codename for this is now AVR turbo.
I tried with the Italians to no avail.

Now its an 644 with the same footprint as an Uno but with video and selfprogramming without a PC.
It still runs on a 328, you have the code but I have to move on.

I'm discussing with Atmel.
« Last Edit: November 22, 2013, 07:24:41 pm by janost » Logged

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I just recieved 2 new 644 samples from Atmel for free.
I'm doing a chipboot with video, or a DOS that can do a selfprogram from a soure.

Yes, a one chip operatingsystem.
 
Logged

Atlanta, USA
Offline Offline
Edison Member
*
Karma: 33
Posts: 1422
AKA: Ray Burne
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I need to find a way to include pure AVR assembler into my functions.

It's do-able with foo.S file name.  Take a look at RancidBacon's V-USB Arduino library for Arduino:
https://code.google.com/p/vusb-for-arduino/

Ray

Logged

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 118
Posts: 4545
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I need to find a way to include pure AVR assembler into my functions.

It's do-able with foo.S file name.  Take a look at RancidBacon's V-USB Arduino library for Arduino:
https://code.google.com/p/vusb-for-arduino/

Not in the Arduino IDE it isn't.

The real problem (as I see it) is that 'normal' Arduino users all use the Arduino IDE. They aren't going to use your code if it requires a different IDE. It's pointless writing it if they aren't going to use it (assuming that's your intention...)

I just saw this page which tells you how to hack the IDE to support assembly language files:

http://www.cs.nmsu.edu/~jcook/arduino/index.php?n=Notes.AssemblyMods

I never tried it but it might be a way to develop the code. When it's all perfect you can write a little program to convert the .s file into a .cpp file.
Logged

No, I don't answer questions sent in private messages...

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Is it possible to define const PROGMEM  inside a void function?

That way the assembly code could be included as words?
Logged

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 118
Posts: 4545
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Is it possible to define const PROGMEM  inside a void function?

That way the assembly code could be included as words?

I really doubt it.

On the other hand you could do something like:
Code:
static const byte myCode[] PROGMEM = { 1,2,3,4 };

void callMyCode()
{
  void (*myCodePtr)() = (void(*)())myCode;
  myCodePtr();
}

You'd have to make sure it's position-independent and I'm not sure how you'd interface it to C++ variables, etc.

Maybe "callMyCode()" could have just enough inline assembly language to load variables into registers before it calls the real code.

Logged

No, I don't answer questions sent in private messages...

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, I'll try that.

People that don't like or understand assembler doesnt want to see the code anyway.
Logged

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 118
Posts: 4545
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, I'll try that.

People that don't like or understand assembler doesnt want to see the code anyway.

True, but there are people out there who *can* read it and maybe fiddle with it to get a different resolution or data layout (or something...)

If you're going to encode it for the IDE, isn't it just as easy to convert asm->inline? All you need is a script to put " \n" around every line of asm.
Logged

No, I don't answer questions sent in private messages...

Offline Offline
Sr. Member
****
Karma: 2
Posts: 349
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

If you're going to encode it for the IDE, isn't it just as easy to convert asm->inline? All you need is a script to put " \n" around every line of asm.

Yes, I'll probably do it that way.
A simple VisualBasic program that reads my ASMfile and displays it as inline assembly.
Then just a simple cut&paste into the IDE.

Nick's C code works as it is now but to do color assembler is a must.

And with the new AVRturbo shield i'm developing, the whole videocode needs to be in the bootsection of the 644.
 
« Last Edit: November 23, 2013, 11:35:42 am by janost » Logged

Pages: 1 [2] 3 4 ... 7   Go Up
Jump to: