darkducke Postado Maio 27, 2008 Denunciar Share Postado Maio 27, 2008 Galera, seguinte tenho uma imagem que é guardada em uma matriz do tipo byte, ela é assim:const byte RPrint [] = { 0x01, 0x01, 0x01, 0x31, 0x00, 0x30, 0x38, 0x30, 0x02, 0x20, 0x89, 0xE0, 0xE3, 0xF0, 0xF9, 0xFD, 0xFD, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFC, 0xF8, 0xF8, 0xF0, 0xE2, 0xE4, 0xDE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x50, 0x80, 0x20, 0x04, 0x03, 0x84, 0xF3, 0xFA, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x7F, 0xBF, 0x3F, 0x3F, 0x7F, 0xBF, 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0x3F, 0x3F, 0x3F, 0x3F, 0x7F, 0x3F, 0x3F, 0xBF, 0x3F, 0x7F, 0x3F, 0x3F' ....como faria para montar cada codigo hexa dentro de uma posição de minha matriz tipo eu tenho ela criada zerada byte RPrint [];tem alguma maneira de fazer isso?porque eu uso a variavel RPrint para imprimir a imagem....Obrigado desde já! Citar Link para o comentário Compartilhar em outros sites More sharing options...
0 KaKarotto Postado Maio 28, 2008 Denunciar Share Postado Maio 28, 2008 Caramba...você teria que quebrar essa string a cada vírgula e pegar os hexas....O embaçado é que teria que transformar esses hexas do tipo string para o tipo byte...Infelizmente eu não sei como fazer essa conversão. Talvez você saiba, se souber avisa, que no resto talvez eu consiga ajudar.É C ou C++? Tenho a impressão que é C++ mas não tenho certeza.Aquele abraço Citar Link para o comentário Compartilhar em outros sites More sharing options...
0 darkducke Postado Maio 28, 2008 Autor Denunciar Share Postado Maio 28, 2008 Um colega em outro forum me passou uma "quse" solução , só o tem um problema justamente na conversão,veja a função:/* FUNÇÃO PARA IMPRESSÃO DE LOGO DINAMICA */ void MENU_LOGOS(void) { char frase[] = "0x00, 0x00, ..."; char * palavra; byte xRPrint [] = {0x00, 0x00, ...}; int i = 0; palavra = strtok(frase, ", "); while (palavra!=NULL) { // xRPrint[i] = (byte)palavra; // memcpy(xRPrint[i], (byte)palavra, sizeof((byte)palavra)); memset(&xRPrint[i], (byte)&palavra, 4); i++; palavra = strtok(NULL, ", "); } PrintImage((byte *)aRPrint, 5, 128, 8); PrintImage((byte *)xRPrint, 5, 128, 8); PrintImage((byte *)RPrint, 5, 128, 8); } /* FIM IMPRESSÃO LOGO DINAMICA */só que não imprime o conteudo, o problema esta na hora de passar o conteudo da variavel palavra, para o xRPrint ..... :( Citar Link para o comentário Compartilhar em outros sites More sharing options...
0 Marcelo Utikawa da Fonseca Postado Junho 3, 2008 Denunciar Share Postado Junho 3, 2008 Quanto a ser C ou C++, não há problema! Pode ser feito com qualquer uma das duas linguagens.Quanto à conversão: realmente não é algo tão simples mas poderia ser muito facilitado se o formato da string fosse outro. Como você recebe esta string? O formato precisa ser mesmo este?Da forma como está você terá um valor para cada 6 caracteres. O algoritmo deve remover os primeiros dois dígitos ("0x") e converter os outros dois. Segue abaixo o código de uma função que converte um char em seu correspondente em hexa:byte ConvHexToByte(char hex) { hex = toupper(hex); if(hex >= '0' && hex <= '9') return (byte)(hex - '0'); if(hex >= 'A' && hex <= 'F') return (byte)(hex - 'A' + 10); else return (byte)(0); } Assim o loop ficaria: while (palavra!=NULL) { palavra += 2; // Avança para após 0x xRPrint[i] = ConvHexToByte(palavra[0])*16 + ConvHexToByte(palavra[1]); i++; palavra = strtok(NULL, ", "); } Só um detalhe: o código não está alocando memória dinamicamente e portanto haverá um limite para a quantidade de dados em xRPrint. Como sabemos que um valor hexa é representado por 6 caracteres na string, poderíamos utilizar o seguinte código para alocar memória dinamicamente: byte *xRPrint; xRPrint = (byte *)(malloc(strlen(palavra)/6 + 1);Eu não sei o tipo de byte mas deve ser um unsigned char. Se não for avise!Devemos somar 1 pois o último dos valores usará apenas 4 caracteres por não possuir a vírgula e o espaço no final, fazendo o cálculo retornar 1 posição a menos que a realmente necessária.Obs: eu montei todos os códigos agora, não testei nem compilei! Se algo der errado avise. Citar Link para o comentário Compartilhar em outros sites More sharing options...
Pergunta
darkducke
Galera, seguinte tenho uma imagem que é guardada em uma matriz do tipo byte, ela é assim:
const byte RPrint [] = {
0x01, 0x01, 0x01, 0x31, 0x00, 0x30, 0x38, 0x30, 0x02, 0x20, 0x89, 0xE0, 0xE3, 0xF0, 0xF9, 0xFD,
0xFD, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE,
0xFE, 0xFE, 0xFE, 0xFE, 0xFF, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE,
0xFE, 0xFE, 0xFF, 0xFE, 0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F,
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F,
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F,
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F,
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F,
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x7F, 0x3F, 0x3F, 0xBF, 0x3F, 0x7F, 0x3F, 0x3F,
0xBF, 0x7F, 0x9F, 0x0F, 0x27, 0x07, 0x03, 0xD1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
só que eu preciso construir esta matriz dinamicamente, este conteudo está nums string tipo
StringImagem = ' 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x7F, 0x3F, 0x3F, 0xBF, 0x3F, 0x7F, 0x3F, 0x3F' ....
como faria para montar cada codigo hexa dentro de uma posição de minha matriz
tipo eu tenho ela criada zerada byte RPrint [];
tem alguma maneira de fazer isso?
porque eu uso a variavel RPrint para imprimir a imagem....
Obrigado desde já!
Link para o comentário
Compartilhar em outros sites
3 respostass a esta questão
Posts Recomendados
Participe da discussão
Você pode postar agora e se registrar depois. Se você já tem uma conta, acesse agora para postar com sua conta.