Let's fix the pictures first:

Right, now we can see them...

The undertype coin is a copper 8 maravedis from Mainland Spain, dated 1606; the denomination is the "VIII" to the right of the shield showing a castle. To the left of the same shield is a little picture of an aqueduct; this is the mintmark for Segovia. Catalogue reference is KM# 15.5.
Now to the countermarks: one side is marked "XII", presumably the re-valuation mark - the new denomination is "12". The otherside is a crown with numerals that appear to be "164".
Two theories on this one, neither of which I can confirm. At the moment I'm leaning towards the second.
1. Spain's neighbour, Portugal, had a a habit of countermarking Spanish coins for their own use, whenever they found them in change while countermarking their own coins for re-use; these marks often appear in the form of a crown with the new value below.
This one is a Portuguese 200 reis re-valiated to 250 reis.
2. Spain itself seems to have done some countermarking of its own coinage, though to a much smaller scale.
This other one is just such a coin, countermarked "VIII" on one side and the date "1654" on the other. This fits more with what we actually see on your coin, (I would suggest a date of "1641"; apparently they had a counterstamping done that year) but these countermarks don't seem to be listed in Krause.
Without knowing the specifics of the countermark, I'd hate to guess the rarity or value.
Don't say "infinitely" when you mean "very"; otherwise, you'll have no word left when you want to talk about something really infinite. - C. S. Lewis